<html>
<head>
  <title>Wiki view</title>
		<script type="text/javascript" src="_js/crypto/sha1.js"></script>
    <script src="/tiny_mce/tiny_mce.js" type="text/javascript"></script>
	<script type="text/javascript">
<!--
tinyMCE.init({
  mode : 'textareas',
  theme: 'advanced',
  theme_advanced_toolbar_location: 'top',
  theme_advanced_toolbar_align: 'left'
});

function hashit(inputvalue, targetfield) {
  targetfield.value = hex_sha1(inputvalue);
  return 1;
}

function copyit(inputvalue, targetfield) {
  targetfield.value = inputvalue;  
  return 1;
}
</script>
    <link  href="/wiki/wiki.css" type="text/css" rel="stylesheet"/>
</head>
<body>
<a href="%[LUA]{{{ print( model.emitContentFromPath('/root/wiki/view-url') ); }}}[LUA]%">view<a><br/>
<hr/>
<form id="wikiedit_form" method="POST" action="%[LUA]{{{ print( model.emitContentFromPath('/root/wiki/view-url') ); }}}[LUA]%">
  <textarea class="wikibody_edit" name="wiki.newdata" cols="120" rows="30">%[LUA]{{{
print( model.emitContentFromPath("/root/wiki/row/data") );
}}}[LUA]%</textarea><br/>
  <input type="checkbox" name="dumpContext"/>
  <input type="submit" value="Save"/>
</form>
</div>
</body>
</html>
